
// #ifndef VUE3
import Vue from 'vue'
import App from './App'

Vue.config.productionTip = false

App.mpType = 'app'

const app = new Vue({
    ...App
})
app.$mount()
// #endif

// #ifdef VUE3
import { createSSRApp } from 'vue'
import App from './App.vue' 
import http from './utils/request.js' // 引入请求封装工具方法
import loadCarBadge from "./utils/loadCarBadge.js" // 动态加载购物车徽标
import checkLogin from './utils/checkLogin'

// 页面加载，立即执行一次获取购物车徽标显示
loadCarBadge()

uni.$loadCarBadge = loadCarBadge;
uni.$checkLogin = checkLogin;

uni.$http = http

// 文件服务器URL
// uni.$baseUrl = "https://localhost:8989/commons/download?picName="
uni.$baseUrl = "https://mall.meibug.cn:8989/commons/download?picName="

export function createApp() { 
  const app = createSSRApp(App)
  return {
    app
  }
}
// #endif